PUT
/
v1
/
system
/
userRoles
/
{type}
/
{id}
Update one User Role
curl --request PUT \
  --url https://{base_url_domain}/api/global/v1/system/userRoles/{type}/{id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "type": "OrganizationUserRole",
  "name": "Administrators",
  "permissions": [
    "warehouse",
    "warehouse/staff",
    "warehouse/staff/time_entry_log",
    "warehouse/staff/time_management",
    "warehouse/staff/time_management/excluded",
    "warehouse/staff/time_management/status_dashboard"
  ]
}'
This response does not have an example.

Authorizations

Authorization
string
header
required

Generate a JWT access token through a Custom Global Integration and provide it with each request in the Authorization header prefixed with "Bearer" and then a single space.

Path Parameters

type
enum<string>
required

Specify the user type to which your operations will be restricted.

Available options:
any,
organization,
client
id
integer
required

The id of the referenced UserRole.

Required range: x >= 1

Body

application/json

Updates an existing UserRole specified by its type and id path parameters and according to the request body.

An OrganizationUserRole is used to provide a specific set of permissions to an organization's user.

type
enum<string>

This is a read-only property that describes the type of object in the response body.

Available options:
OrganizationUserRole
name
string

The name of the User Role.

Maximum length: 50
Example:

"Administrators"

permissions
string[]

A list of permissions for a single role.

Example:
[
"warehouse",
"warehouse/staff",
"warehouse/staff/time_entry_log",
"warehouse/staff/time_management",
"warehouse/staff/time_management/excluded",
"warehouse/staff/time_management/status_dashboard"
]

Response

OK - The operation completed successfully and there is no response body.